egret_h5 = {};
egret_h5.prefix = "";
egret_h5.loadScript = function(b, a) {
    var c = 0;
    var d = function() {
        egret_h5.loadSingleScript(egret_h5.prefix + b[c], function() {
            c++;
            if (c >= b.length) {
                a()
            } else {
                d()
            }
        })
    };
    d()
}
;
egret_h5.loadSingleScript = function(c, a) {
    var b = document.createElement("script");
    if (b.hasOwnProperty("async")) {
        b.async = false
    }
    b.src = c;
    b.addEventListener("load", function() {
        this.removeEventListener("load", arguments.callee, false);
        a()
    }, false);
    document.body.appendChild(b)
}
;
egret_h5.preloadScript = function(a, b) {
    if (!egret_h5.preloadList) {
        egret_h5.preloadList = []
    }
    egret_h5.preloadList = egret_h5.preloadList.concat(a.map(function(c) {
        return b + c
    }))
}
;
egret_h5.startLoading = function() {
    var a = egret_h5.preloadList;
    egret_h5.loadScript(a, egret_h5.startGame)
}